package indigo.captcha.config;

import static indigo.captcha.config.ImageCaptchaConfiguration.DEFAULT_CASE_SENSITIVE;
import static indigo.captcha.config.ImageCaptchaConfiguration.DEFAULT_FONT_FILE_LOCATION;
import static indigo.captcha.config.ImageCaptchaConfiguration.DEFAULT_HEIGHT;
import static indigo.captcha.config.ImageCaptchaConfiguration.DEFAULT_LENGTH;
import static indigo.captcha.config.ImageCaptchaConfiguration.DEFAULT_MAX_FONT_SIZE;
import static indigo.captcha.config.ImageCaptchaConfiguration.DEFAULT_MAX_STORE_SIZE;
import static indigo.captcha.config.ImageCaptchaConfiguration.DEFAULT_PATH;
import static indigo.captcha.config.ImageCaptchaConfiguration.DEFAULT_TIME_TO_LIVE;
import static indigo.captcha.config.ImageCaptchaConfiguration.DEFAULT_WIDTH;
import static java.lang.annotation.ElementType.TYPE;
import static java.lang.annotation.RetentionPolicy.RUNTIME;

import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;

import org.springframework.context.annotation.Import;
import org.springframework.core.annotation.AliasFor;

@Documented
@Retention(RUNTIME)
@Target(TYPE)
@Import(ImageCaptchaConfiguration.class)
public @interface EnableImageCaptcha {
	@AliasFor("path")
	String value() default DEFAULT_PATH;

	@AliasFor("value")
	String path() default DEFAULT_PATH;

	boolean caseSensitive() default DEFAULT_CASE_SENSITIVE;

	int timeToLive() default DEFAULT_TIME_TO_LIVE;

	int maxStoreSize() default DEFAULT_MAX_STORE_SIZE;

	int width() default DEFAULT_WIDTH;

	int height() default DEFAULT_HEIGHT;

	int length() default DEFAULT_LENGTH;

	int maxFontSize() default DEFAULT_MAX_FONT_SIZE;

	String[] fontFileLocations() default DEFAULT_FONT_FILE_LOCATION;
}
